package com.foreknow.demo3;

public class MethodDemo4 {
    public static void m1(int a) {
        System.out.println(a);
    }

    public static int m2(int b) {
        return b;
    }

    public static void m3(String[] strs) {
        for(int i = 0;i<strs.length;i++){
            System.out.println(strs[i]);
        }
    }

    public static int[] m4() {
        int[] array = {1,2,3,4};
        return array;
    }

    public static void main(String[] args) {
        MethodDemo4.m1(12);
        int num = MethodDemo4.m2(13);
        String[] str1 = {"aa","bb","cc"};
        MethodDemo4.m3(str1);
        System.out.println("------------------------------------");
        int[] a = MethodDemo4.m4();
        for(int i = 0;i<a.length;i++){
            System.out.println(a[i]);
        }
        System.out.println(num);
    }


}
